<!DOCTYPE html>
<html lang="en" class="no-js" xmlns:th="http://www.thymeleaf.org" xmlns:layout="http://www.ultraq.net.nz/web/thymeleaf/layout" layout:decorator="admin/layout">
<head>

</head>
<body>
<div layout:fragment="content">
	<script th:inline="javascript">

		$(document).ready(function() {

			$("#form_goods_brand").validate({
				rules:{
					deadline:{
						required:true,
						min:5,
						max:254,
						digits:true
					},
					baseNumber:{
						required:true,
						min:0,
						digits:true
					},
					waterScale:{
						required:true,
						min:4,
						number:true
					}
				},
				messages:{
					deadline:{
						required:"必须填写",
						min:"最短为五秒",
						digits:"必须为整数"
					},
					baseNumber:{
						required:"必须填写",
						min:"最小为0",
						digits:"必须为整数"
					},
					waterScale:{
						required:"必须填写",
						min:"最小为0",
						number:"必须是数字"
					}
				}
			});
		});
		
	</script>
	<div class="row">
		<div class="col-md-7">
		<div class="portlet box blue">
			<div class="portlet-title">
				<div class="caption">
					<i class="fa fa-gift"></i>
					<th:block th:text="${game.name+'基本信息'}"></th:block>
				</div>
			</div>
			<div class="portlet-body form">
				<form role="form" id="form_goods_brand" name="form_goods_brand" th:action="@{'/admin/game/luck28/save'}" th:object="${game}" method="post" class="form-horizontal form-bordered">
					<input type="hidden" th:field="*{id}" />
					<div class="form-body">
						<div class="form-group">
							<label class="control-label col-md-3">游戏名称</label>							
							<div class="col-md-7">
								<span class="form-control" th:text="${game.name}"></span>
							</div>
						</div>
						<div class="form-group">
							<label class="control-label col-md-3">开奖频率</label>
							<div class="col-md-7">
							<div class="input-group">
								<span class="form-control" th:text="${game.frequency}"></span>
								<span class="input-group-addon">秒</span>
							</div>
							</div>
						</div>
						<div class="form-group">
							<label class="control-label col-md-3">不可投注时间<span class="required" aria-required="true">* </span></label>
							<div class="col-md-7">
								<div class="input-group">
									<input type="text" id="deadline" class="form-control" placeholder="不可投注时间" th:field="*{deadline}" />
									<span class="input-group-addon">秒</span>
								</div>
							</div>
						</div>
						<div class="form-group">
							<label class="control-label col-md-3">抽取投注千分比<span class="required" aria-required="true">* </span></label>
							<div class="col-md-7">
								<div class="input-group">
									<input type="text" id="waterScale" class="form-control" placeholder="抽取投注千分比" th:field="*{waterScale}" />
									<span class="input-group-addon">‰</span>
								</div>
							</div>
						</div>
						<div class="form-group">
							<label class="control-label col-md-3">金币基数<span class="required" aria-required="true">* </span></label>
							<div class="col-md-7">
								<input type="text" id="baseNumber" class="form-control" placeholder="金币基数" th:field="*{baseNumber}" />
							</div>
						</div>
					</div>	
					<div class="form-actions fluid">
						<div class="col-md-offset-3 col-md-9">
							<button type="submit" id="bt_submit" name="bt_submit" class="btn blue">提交</button>
						</div>
					</div>
				</form>		
			</div>
		</div>
			
		</div>
	</div>
</div>	
</body>
</html>